<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
{#  <title>ATTACK</title>#}

  <!-- Google Font: Source Sans Pro -->
  <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700&display=fallback">
  <!-- Font Awesome -->
  <link rel="stylesheet" href="/static/plugins/fontawesome-free/css/all.min.css">
  <!-- Ionicons -->
  <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
  <!-- Tempusdominus Bootstrap 4 -->
  <link rel="stylesheet" href="/static/plugins/tempusdominus-bootstrap-4/css/tempusdominus-bootstrap-4.min.css">
  <!-- iCheck -->
  <link rel="stylesheet" href="/static/plugins/icheck-bootstrap/icheck-bootstrap.min.css">
  <!-- JQVMap -->
  <link rel="stylesheet" href="/static/plugins/jqvmap/jqvmap.min.css">
  <!-- Theme style -->
  <link rel="stylesheet" href="/static/dist/css/adminlte.min.css">
  <!-- overlayScrollbars -->
  <link rel="stylesheet" href="/static/plugins/overlayScrollbars/css/OverlayScrollbars.min.css">
  <!-- Daterange picker -->
  <link rel="stylesheet" href="/static/plugins/daterangepicker/daterangepicker.css">
  <!-- summernote -->
  <link rel="stylesheet" href="/static/plugins/summernote/summernote-bs4.min.css">
{% block header_js %}
{% endblock %}
</head>
<body class="hold-transition sidebar-mini layout-fixed">
<div class="wrapper">
    <!-- Preloader -->
    <div class="preloader flex-column justify-content-center align-items-center">
    <img class="animation__shake" src="/static/dist/img/AdminLTELogo.png" alt="AdminLTELogo" height="60" width="60">
    </div>

    <!-- Navbar -->
    <nav class="main-header navbar navbar-expand navbar-white navbar-light pull-right">
    <!-- Left navbar links -->
    <ul class="navbar-nav">
      <li class="nav-item">
        <a class="nav-link" data-widget="pushmenu" href="#" role="button"><i class="fas fa-bars"></i></a>
      </li>
      <li class="nav-item d-none d-sm-inline-block">
        <a href="{% url 'home' %}" class="nav-link">Home</a>
      </li>
      <li class="nav-item d-none d-sm-inline-block nav-tabs-right">
        <a href="/logout" class="nav-link">logout</a>
      </li>
    </ul>
    </nav>

    <!-- Main Sidebar Container -->
    <aside class="main-sidebar sidebar-dark-primary elevation-4">
        <a href="#" class="brand-link" style="text-align: center;">
          <span class="brand-text font-weight-light" style="font-size:20px;">白泽安全知识图谱平台</span>
        </a>
        <!-- Sidebar -->
        <div class="sidebar">
          <!-- Sidebar user panel (optional) -->
          <div class="user-panel mt-3 pb-3 mb-3 d-flex">
            <div class="image">
              <img src="/static/dist/img/user2-160x160.jpg" class="img-circle elevation-2" alt="User Image">
            </div>
            <div class="info">
                <a href="#" class="d-block">{{ request.user }}</a>
                <a href="#"><i class="fa fa-circle text-success"></i> Online</a>
            </div>
          </div>

          <!-- Sidebar Menu -->
          <nav class="mt-2">
            <ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false" id="nav">
              <!-- Add icons to the links using the .nav-icon class
                   with font-awesome or any other icon font library -->
              <li class="nav-item" id="nav-home">
                <a href="{% url 'home' %}" class="nav-link" id="nav-home-home">
                  <i class="nav-icon fas fa-th-large"></i>
                  <p>
                    首页
                  </p>
                </a>
              </li>
              <li class="nav-item" id="nav-attack">
                <a href="{% url 'attack_overview' %}" class="nav-link">
                  <i class="nav-icon fas  fa-folder-open"></i>
                  <p>
                    ATT&CK管理
                    <i class="fas fa-angle-left right"></i>
                  </p>
                </a>
                <ul class="nav nav-treeview">
                      <li class="nav-item">
                        <a href="{% url 'attack_overview' %}" class="nav-link" id="nav-attack-overview">
                          <i class="far fa-circle nav-icon"></i>
                          <p>总览</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_tactics' %}" class="nav-link" id="nav-attack-tactics">
                          <i class="far fa-circle nav-icon"></i>
                          <p>战术管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_technology' %}" class="nav-link" id="nav-attack-technology">
                          <i class="far fa-circle nav-icon"></i>
                          <p>技术管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_sub_technology' %}" class="nav-link" id="nav-attack-sub_technology">
                          <i class="far fa-circle nav-icon"></i>
                          <p>子技术管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_mitigations' %}" class="nav-link" id="nav-attack-mitigations">
                          <i class="far fa-circle nav-icon"></i>
                          <p>缓解措施管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_organization' %}" class="nav-link" id="nav-attack-organization">
                          <i class="far fa-circle nav-icon"></i>
                          <p>组织管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_software' %}" class="nav-link" id="nav-attack-software">
                          <i class="far fa-circle nav-icon"></i>
                          <p>软件管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_data_sources' %}" class="nav-link" id="nav-attack-data_sources">
                          <i class="far fa-circle nav-icon"></i>
                          <p>数据资源管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_datasource_component' %}" class="nav-link" id="nav-attack-datasource_component">
                          <i class="far fa-circle nav-icon"></i>
                          <p>数据组件</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_campaign' %}" class="nav-link" id="nav-attack-campaign">
                          <i class="far fa-circle nav-icon"></i>
                          <p>战役管理</p>
                        </a>
                      </li>
                      <li class="nav-item">
                        <a href="{% url 'attack_relationship' %}" class="nav-link" id="nav-attack-relationship">
                          <i class="far fa-circle nav-icon"></i>
                          <p>关系管理</p>
                        </a>
                      </li>
                </ul>
              </li>
              <li class="nav-item" id="nav-log">
                <a href="#" class="nav-link">
                  <i class="nav-icon fas  fa-database"></i>
                  <p>
                    日志查询
                    <i class="fas fa-angle-left right"></i>
                  </p>
                </a>
                <ul class="nav nav-treeview">
                  <li class="nav-item">
                    <a href="{% url 'log_query' %}" class="nav-link" id="nav-log-log_query">
                      <i class="far fa-circle nav-icon"></i>
                      <p>日志管理</p>
                    </a>
                  </li>
                </ul>
              </li>
              <li class="nav-item" id="nav-rule">
                <a href="#" class="nav-link">
                  <i class="nav-icon fas   fa-crosshairs"></i>
                  <p>
                    命中规则
                    <i class="fas fa-angle-left right"></i>
                  </p>
                </a>
                <ul class="nav nav-treeview">
                  <li class="nav-item">
                    <a href="{% url 'rule' %}" class="nav-link" id="nav-rule-rule_target">
                      <i class="far fa-circle nav-icon"></i>
                      <p>命中规则管理</p>
                    </a>
                  </li>
                </ul>
              </li>
              <li class="nav-item" id="nav-threaten">
                <a href="#" class="nav-link">
                  <i class="nav-icon fas   fa-heartbeat"></i>
                  <p>
                    威胁命中
                    <i class="fas fa-angle-left right"></i>
                  </p>
                </a>
                <ul class="nav nav-treeview">
                  <li class="nav-item">
                    <a href="{% url 'threaten' %}" class="nav-link" id="nav-threaten-threaten">
                      <i class="far fa-circle nav-icon"></i>
                      <p>威胁命中管理</p>
                    </a>
                  </li>
                </ul>
              </li>
              <li class="nav-item" id="nav-information">
                <a href="#" class="nav-link">
                  <i class="nav-icon fas  fa-newspaper"></i>
                  <p>
                    情报命中
                    <i class="fas fa-angle-left right"></i>
                  </p>
                </a>
                <ul class="nav nav-treeview">
                  <li class="nav-item">
                    <a href="{% url 'information' %}" class="nav-link" id="nav-information-information">
                      <i class="far fa-circle nav-icon"></i>
                      <p>情报命中管理</p>
                    </a>
                  </li>
                </ul>
              </li>
          </ul>
          </nav>
          <!-- /.sidebar-menu -->
        </div>
    <!-- /.sidebar -->
    </aside>

    <div class="content-wrapper">
        <!-- Main content -->
        <section class="content" style="font-size:13px">
            {% block content %}
            {% endblock %}
        </section>
        <!-- /.content -->
    </div>
    <!-- /.content-wrapper -->
    <footer class="main-footer">
        <strong>AHJ-SEC © 2022 <a href="https://sec-ajh.com/">AJH-SEC</a>.</strong>
        All rights reserved.
    </footer>
</div>
<!-- ./wrapper -->
{% block footer_block %}
{% endblock %}
<!-- jQuery -->
<script src="/static/plugins/jquery/jquery.min.js"></script>
<!-- jQuery UI 1.11.4 -->
<script src="/static/plugins/jquery-ui/jquery-ui.min.js"></script>
<!-- Resolve conflict in jQuery UI tooltip with Bootstrap tooltip -->
<script>
  $.widget.bridge('uibutton', $.ui.button)
</script>
<!-- Bootstrap 4 -->
<script src="/static/plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
<!-- ChartJS -->
<script src="/static/plugins/chart.js/Chart.min.js"></script>
<!-- Sparkline -->
<script src="/static/plugins/sparklines/sparkline.js"></script>
<!-- JQVMap -->
<script src="/static/plugins/jqvmap/jquery.vmap.min.js"></script>
<script src="/static/plugins/jqvmap/maps/jquery.vmap.usa.js"></script>
<!-- jQuery Knob Chart -->
<script src="/static/plugins/jquery-knob/jquery.knob.min.js"></script>
<!-- daterangepicker -->
<script src="/static/plugins/moment/moment.min.js"></script>
<script src="/static/plugins/daterangepicker/daterangepicker.js"></script>
<!-- Tempusdominus Bootstrap 4 -->
<script src="/static/plugins/tempusdominus-bootstrap-4/js/tempusdominus-bootstrap-4.min.js"></script>
<!-- Summernote -->
<script src="/static/plugins/summernote/summernote-bs4.min.js"></script>
<!-- overlayScrollbars -->
<script src="/static/plugins/overlayScrollbars/js/jquery.overlayScrollbars.min.js"></script>
<!-- AdminLTE App -->
<script src="/static/dist/js/adminlte.js"></script>
<script src="/static/dist/js/pages/dashboard.js"></script>
<script src="/static/js/jquery.form.js"></script>
{#<script src="bower_components/jquery-slimscroll/jquery.slimscroll.min.js"></script>#}
<script>
    function init_nav() {
        $("#nav li").each(function (i, n) {
            $(this).removeClass("active")
        });
    }
    var nav = "#nav-{%block navname %}{% endblock %}";
    var son_nav = nav + "-" + "{% block navSon %}{% endblock %}";
    var deep_nav = son_nav + "-" + "{% block navDeep %}{% endblock%}";
    console.log(nav)
    console.log(son_nav)
    console.log(deep_nav)
    $(nav).addClass("menu-is-opening menu-open");
    $(son_nav).addClass("active");
    $(deep_nav).addClass("active");
</script>

{% block footer_js %}
{% endblock %}
</body>
</html>
